﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Demo1
{
    class Program
    {
        static void Main(string[] args)
        {
            Task T1 = new Task(TaskType.送信, "sonxin", NPCType.任务);
            Task T2 = new Task(TaskType.杀怪, "shaguai", NPCType.任务);
            Task T3 = new Task(TaskType.采集, "caiji", NPCType.任务);
            Hello(T1); Hello(T2); Hello(T3);

            Console.WriteLine("--------------------------------");

            Pedlar P1 = new Pedlar(PedlarType.武器, "wuqi", NPCType.商贩);
            Pedlar P2 = new Pedlar(PedlarType.材料, "cailiao", NPCType.商贩);
            Pedlar P3 = new Pedlar(PedlarType.食物, "shiwu", NPCType.商贩);
            Hello(P1); Hello(P2); Hello(P3);

            Console.WriteLine("--------------------------------");

            Blacksmith B1 = new Blacksmith(BlacksmithType.修补, "wuqi", NPCType.铁匠);
            Blacksmith B2 = new Blacksmith(BlacksmithType.强化, "cailiao", NPCType.铁匠);
            Blacksmith B3 = new Blacksmith(BlacksmithType.打造, "shiwu", NPCType.铁匠);
            Hello(B1); Hello(B2); Hello(B3);
            Console.ReadKey();
        }
        static void Hello(NPC npc)
        {
            npc.Speak();
        }
    }
}
